// The Vue build version to load with the `import` command
// (runtime-only or standalone) has been set in webpack.base.conf with an alias.
import Vue from 'vue'
import App from './App'
import router from './router/index'
import '@/assets/css/reset.css'
import elementUI from 'element-ui'
import 'element-ui/lib/theme-chalk/index.css';
import VueAMap from "vue-amap"
Vue.use(elementUI)
Vue.use(VueAMap)

Vue.config.productionTip = false;

VueAMap.initAMapApiLoader({
    key: "5ccb504b2684206a85954dcfea74f44d",
    plugin: [
        "AMap.Autocomplete", //输入提示插件
        "AMap.PlaceSearch", //POI搜索插件
        "AMap.Scale", //右下角缩略图插件 比例尺
        "AMap.OverView", //地图鹰眼插件
        "AMap.ToolBar", //地图工具条
        "AMap.MapType", //类别切换控件，实现默认图层与卫星图、实施交通图层之间切换的控制
        "AMap.PolyEditor", //编辑 折线多，边形
        "AMap.CircleEditor", //圆形编辑器插件
        "AMap.Geolocation" //定位控件，用来获取和展示用户主机所在的经纬度位置
    ],
    uiVersion: "1.0"
});

// Vue.prototype.goPage=(pathName) => {
//     this.$router.push({
//         name: pathName,
//         query: {
//             // 保证每次点击路由的query项都是不一样的，确保会重新刷新view
//             t: +new Date()
//         }
//     })
// };

/* eslint-disable no-new */
new Vue({
  el: '#app',
  router,
  components: { App },
  template: '<App/>'
});

